﻿



using System; 
using System.Collections;
using System.Collections.Generic ;
using System.Runtime.Serialization;

namespace UFIDA.U9.Cust.U9Demo.DeliveryBP
{
	/// <summary>
	/// 送货单行DTO DTO :自定义的数据传输类型 
	/// 
	/// </summary>
	[DataContract(Name = "UFIDA.U9.Cust.U9Demo.DeliveryBP.DeliveryLineDTOData", Namespace = "http://www.UFIDA.org/EntityData",IsReference=true)]
	[Serializable]
	[KnownType("GetKnownTypes")]
	public partial class DeliveryLineDTOData : UFSoft.UBF.Business.DataTransObjectBase
	{
		public static IList<Type> GetKnownTypes()
        {
            IList<Type> knownTypes = new List<Type>();
                          
            knownTypes.Add(typeof(UFSoft.UBF.Util.Data.MultiLangDataDict));
            return knownTypes;
        }
		/// <summary>
		/// Default Constructor
		/// </summary>
		public DeliveryLineDTOData()
		{
			initData();
		}
		private void initData()
		{
		
					ToQty=0m; 

			//调用默认值初始化服务进行配置方式初始化
			UFSoft.UBF.Service.DTOService.InitConfigDefault(this);
		}
		[System.Runtime.Serialization.OnDeserializing]
        internal void OnDeserializing(System.Runtime.Serialization.StreamingContext context)
        {
			 initData();
        }
		#region Do SerializeKey -ForDTODataType
		//只为处理集合型EntityKey。原因集合型EntityKey由于使用臫的集合对象，无法实现数据共享.-UBF专用.
		public void DoSerializeKeyList(IDictionary dict)
		{
			if (dict == null ) dict = new Hashtable() ;
			if (dict[this] != null)
				return ;
			dict[this] = this;
	        	        
		}
		#endregion 
		/// <summary>
		/// Constructor Full Argument
		/// </summary>
		public DeliveryLineDTOData(  Int64 deliveryLineID  , System.Decimal toQty  )
		{
			initData();
			this.DeliveryLineID = deliveryLineID;
			this.ToQty = toQty;
		}
		#region System Fields 
		//--系统字段,目前没有.EntityData上有相应的字段,用于保存相关的实体状态信息,DTO上没有状态信息.	
		#endregion
		
		#region DTO Properties 
	
		private UFSoft.UBF.Business.BusinessEntity.EntityKey m_deliveryLineID_SKey ;
		/// <summary>
		/// 送货单行 序列化Key属性。（传递跨组织序列列字段）
		/// 送货单行DTO.Misc.送货单行
		/// </summary>
		[DataMember(IsRequired=false)]
		public UFSoft.UBF.Business.BusinessEntity.EntityKey DeliveryLineID_SKey
		{
			get 
			{
				return m_deliveryLineID_SKey ;					
			}
			set
			{
				m_deliveryLineID_SKey =value;	
			}
		}


		/// <summary>
		/// 送货单行
		/// 送货单行DTO.Misc.送货单行
		/// </summary>
		[DataMember(IsRequired=false)]
		public Int64 DeliveryLineID
		{
			get	
			{	
				if (DeliveryLineID_SKey == null)
					return UFSoft.UBF.Business.Entity.EmptyObjectValue ;
				else
					return DeliveryLineID_SKey.ID ;
			}
			set	
			{	
				if (value == 0 || value == UFSoft.UBF.Business.Entity.EmptyObjectValue )
					DeliveryLineID_SKey = null ;
				else
				{
					if (DeliveryLineID_SKey == null )
						DeliveryLineID_SKey = new UFSoft.UBF.Business.BusinessEntity.EntityKey(value,"UFIDA.U9.Cust.U9Demo.DeliverBE.DeliveryLine") ;
					else
						DeliveryLineID_SKey.ID = value ;
				}
			}
		}
			
		

		/// <summary>
		/// 转单数量
		/// 送货单行DTO.Misc.转单数量
		/// </summary>
		[DataMember(IsRequired=false)]
		private System.Decimal m_toQty ;
		public System.Decimal ToQty
		{
			get	
			{	
				return m_toQty ;
			}
			set	
			{	
				m_toQty = value ;	
			}
		}
			
		#endregion	

		#region Multi_Fields
				
		#endregion 
	} 	
}

	
